<?php
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/style.css";
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/color.css";
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/public.css";
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/cart_index.css";


$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery-1.6.2.min.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.bgiframe.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.timer.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.weebox.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.touchwipe.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/fastclick.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/fanwe_utils/fanweUI.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/fanwe_utils/fanweUI.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/script.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/script.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/sms_verify.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/sms_verify.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/cart_index.js";
//$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/cart_index.js";


?>

{include file="inc/header_title_only.html"}
{include file="inc/header_index_new.html"}
<link rel="stylesheet" href="css/index.css">
<script type="text/javascript">
	//减少移动端触发"Click"事件时300毫秒的时间差
window.addEventListener('load', function() {
    FastClick.attach(document.body);
}, false);
var jsondata = {$jsondata};
</script>
<form name="buy_form" id="buy_form" action="{url x="index" r="cart#check_cart"}" method="post">
<div class="wrap">
    {if $data.cart_list}
		<ul class="cart-list">
	{foreach from=$data.cart_list item=item}
			<li class="split-line" data-id="{$item.id}">
			  <div class="goods-img">
          {if $item.min_buy eq 10}
            <div class="tenyen"></div>
          {elseif $item.unit_price eq 100}
            <div class="hundredyen"></div>
          {/if}
			    <img src="{$item.deal_icon}" alt="{$item.deal_icon}">
			  </div>
			  <div class="txtbox">
					<div class="flex-box">
						<h2>{$item.name}</h2>
					</div>
					<!--p>总需:<span>{$item.max_buy}</span>人次，剩余<span class="rest">{$item.residue_count}</span>人次</p-->
				    <div class="select-bar">
				  	<p>购买数量</p>
					  	<div class="select-wrap">
						  	<div class="select">
						  		<a href="javascript:void(0);" class="iconfont split-line-right minus" data-id="{$item.id}">&#xe6d3;</a>
						  		<input name="num[{$item.id}]" class="buy_number buy-num-{$item.id}" type="tel" value="{$item.number}" data-id="{$item.id}" />
						  		<a href="javascript:void(0);" class="iconfont split-line-left plus" data-id="{$item.id}">&#xe6d1;</a>
						  		<em>理性购物，欢乐生活</em>
						  	</div>
					  	</div>
				  	<i class="iconfont del-item-btn" data-id="{$item.id}">&#xe68d;</i>
				    </div>
			  </div>
			  <div class="clear"></div>
			</li>
	{/foreach}

		</ul>
    {else}
		<div class="null_data">
		<p class="icon"><i class="iconfont">&#xe6e8;</i></p>
		<p class="message">购物车暂无数据</p>
		</div>

    {/if}

    </div>

<div class="cart-floot">
    <div class="cart-count-box split-line-top">
        <div  class="cart-item-number">共{$data.total_data.cart_item_number}商品，总计: <span>{$data.total_data.total_price}元</span></div><input class="check-btn" type="submit" value="结算">
    </div>
</div>

</form>
{include file="inc/footer_menu.html"}
{include file="inc/footer_index.html"}
